
// import post from './http';
import obj from './http';
const { get, post } = obj;

export const Code = 200;//1正确，2错误 返回的状态码

export const Login = p => post('/login', p);//登录
export const OutLogin = p => post('/logout', p);//退出登录
export const UpdatePassword = p => post('/user/updatePassword', p);//修改密码



export const UserList = p => get('/user/userList', p);//获取用户列表
export const DeleteUser = p => get('/user/deleteUser', p);//批量删除用户



export const LoginAllPermission = p => get('/user/role/auth/user', p);//登录后获取当前用户的所有权限

export const AddUserName = p => post('/user/save', p);//批量添加用户
export const GetClassificationList = p => get('/classification/classificationList', p);//获取所有分类列表
export const SaveOrUpdateClassification = p => post('/classification/saveOrUpdateClassification', p);//修改或新建工单节点数据
export const DeleteClassification = p => post('/classification/deleteClassification', p);//逻辑删除节点分类信息

export const SaveOrUpdatCityArea = p => post('/pca/addOrUpdate', p);//修改或新建省市区节点
export const GetCityAreaList = p => get('/pca/list', p);//获取城市区数据

export const DeleteCityArea = p => post('/pca/deleteBatch', p);//批量删除省市区节点
export const GetWorkOrderByConditions = p => get('/order/getWorkOrderByConditions', p);//查询工单
export const AddWorkOrder = p => post('/order/saveWorkOrder', p);//客服创建工单,不传id

export const LockWorkOrder = p => get('/order/updateWorkOrderTo1', p);//锁定工单,修改操作
export const ReleaseWorkOrder = p => get('/order/updateWorkOrderTo0', p);//释放工单,修改操作

export const AddAdditionalComment = p => post('/order/addAdditionalComment', p);//添加附加意见
export const AddHandleComment = p => post('/order/addHandleComment', p);//添加处理意见


// 导入工单分类
export const Roles = p => post('/order/addHandleComment', p);//
export const WorkClassList = p => post('/order/addHandleComment', p);//

export const GetUsedWorkOrder = p => get('order/getUsedWorkOrder', p);//未释放的工单


export const DeleteCache = p => post('/classification/deleteCache', p);//清除缓存







// 角色权限

export const IncludeUsers = p => get('/user/role/users', p);//包含用户列表
export const WorkJobList = p => get('/work-job/list', p);//岗位类型--岗位列表
export const AddWorkJob = p => post('/work-job/', p);//岗位类型--新增岗位
export const DeleteWorkJob = p => post('/work-job/', p);//岗位类型--删除岗位
export const SearchWorkJob = p => get('/work-job/page', p);//岗位类型--查找岗位

// 人员管理
export const ManagerUserList = p => get('/manager/user/page', p);//人员管理列表
export const ManagerUserAllList = p => get('/manager/user/nopage', p);//人员管理列表-所有
export const AddManagerUser = p => post('/manager/user', p);//人员管理--添加
export const DeletManagerUser = p => post('/manager/user/', p);//人员管理--删除
export const EditManagerUser = p => get('/manager/user', p);//人员管理--编辑
export const ManagerUserStop = p => post('/manager/user/is-stop', p);//启用/禁用 用户
export const DeleteManagerUser = p => post('/manager//user/', p);//管理员删除用户

// 组织架构
export const RolePermissionModify = p => post('/user/role/auth', p);//设置角色权限--修改
export const GetRolePermissions = p => get('/user/role/auth', p);//获取角色对应权限
export const GetRoleList = p => get('/user/role/', p);//获取角色列表
export const GetAllPermissions = p => get('/user/role/auths', p);//获取全部权限
export const GetManagerUserList = p => get('/manager/user/list', p);//查询地市下的用户页面
export const AddRole = p => post('/user/role/', p);//角色权限--新增角色
export const AddInstitution = p => post('/manager/region', p);//新增机构
export const EditInstitution = p => post('/manager/admin/user', p);//编辑
export const GetAddInstitution = p => post('/manager/region', p);//获取新增机构的参数
export const GetOrganizationInformation = p => get('/manager/region', p);//获取组织架构信息
export const GetAllOrganizations = p => get('/manager/all-region-trees', p);//所有组织 组织架构 部门编号
export const DeleteRole = p => post('/user/role/', p);//删除角色
export const DeleteOrganization = p => post('/region', p);//删除组织
export const ModifyOrganization = p => post('/region', p);//
export const LoginStatus = p => post('/manager/user/login-status', p);//启用/禁用 用户登录
export const ManagerUserListExcel = p => get('/manager/user/list/excel', p);//查询地市下的用户页面-导出excel


/**
//  * 父级地市id
//  */
// private Integer pRegionId;

// /**
//  * 地市ID
//  */
// private Integer regionId;

// /**
//  * 层级id
//  */
// private String levelId;

// /**
//  * 地市名称
//  */
// private String regionName;

// /**
//  * 地市编号
//  */
// private String regionCode;

// /**
//  * 是否为督办部门
//  */
// private Integer isWatchRegion;

// /**
//  * 是否为转办部门
//  */
// private Integer isTransferRegion;

// /**
//  * 是否为承办部门
//  */
// private Integer isAcceptRegion;

// /**
//  * 排序
//  */
// private Integer sort;






